﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="index.aspx.cs" Inherits="Default2" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>健新在线考试系统</title>
    <link href="../css/Common.css" rel="stylesheet" type="text/css" />
    <script src="../JS/jquery-1.6.min.js" type="text/javascript"></script>
    <style type="text/css">
        #main {
        }

        #head {
            width: 100%;
            height: 170px;
        }

        #content {
            border: 2px solid;
            border-color: lightgrey;
            border-radius: 10px;
            width: 25%;
            height: 40%;
            margin-left: 60%;
        }

        #login {
            height: 45%;
            width: 100%;
        }

        #left {
            width: 58%;
            height: 50%;
            float: left;
            margin: 50px 0px 0px 25px;
            text-align: center;
        }

        body {
            margin: 0px;
        }

        .ct {
            height: 54px;
            margin-left: 10%;
            line-height: 20px;
            margin-top: 12px;
            width: 244px;
        }

        .ct_right {
            width: 300px;
            float: left;
        }

        .ct_left {
            width: 80px;
            float: left;
        }

        .login_btn {
            margin-left: 115px;
        }

        .footer {
        }


        .head_1 {
            text-align: right;
            height: 50px;
            margin-top: 0px;
        }

            .head_1 a {
                height: 50px;
                color: white;
                text-decoration: none;
                font-size: 12px;
            }

        a {
            text-decoration: none;
            color: Black;
        }

        .btn {
            /*Width: 80%;
            Height: 40px;
            border-radius:5px;*/
            width: 80%;
            height: 40px;
            border: 0px;
            font-size: 20px;
            color: grey;
            padding-top: 5px;
            margin-left: 10%;
            background-color: #ffffff;
            border-radius: 3px;
            border: 1px solid grey;
        }

            .btn:hover {
                background-color: #ffffff;
                border-radius: 3px;
                border: 0px;
                border: 1px solid #0099ff;
                box-shadow: 2px 1px 2px 1px #0099ff;
            }

            .btn:focus {
                background-color: #ffffff;
                border-radius: 3px;
                border: 0px;
                border: 1px solid #0099ff;
                box-shadow: 1px 1px 1px 0.5px #0099ff;
            }


        #Image1 {
            margin-top: 1px;
        }

        input.button {
            width: 88%;
            height: 40px;
            background-color: #0099ff;
            color: #FFFFFF;
            font-size: 20px;
            border-radius: 2px;
            float: left;
        }

            input.button:hover {
                background-color: #009900;
            }
    </style>

    <script type="text/javascript">
        window.onload = function () {
            let main = document.getElementById("main");
            main.style.height = window.innerHeight;
            main.style.width = window.innerWidth * 0.7;
            //判断一下当前是不是做顶层，如果不是，则做一下顶层页面重定向
            if (window != top) {
                top.location.href = location.href;
            }
        }
        //$(function () {
        //   
        //    if (window != top) {
        //        top.location.href = location.href;
        //    }
        //});  
        function submitClick() {
            var uName = "";
            var uPass = "";
            var uCode = "";
            uName = $("#TextBox5").val();
            uPass = $("#TextBox6").val();
            if (uName == "") {
                alert('请填写用户名');
                $("#TextBox5").focus();
                return;
            }
            if (uPass == "") {
                alert('请填写密码');
                $("#TextBox6").focus();
                return;
            }
            var ob;
            //ob = document.getElementByid("ImageButton1");
            //ob.focus();
            //ob.click();
            //document.getElementById("ImageButton1").click();            $("#loginFrm").submit();        }

    </script>

</head>
<body id="loginbody">
    <form id="loginFrm" runat="server">
        <div id="main">
            <div id="head">
                <div class="head_1">
                </div>
            </div>
            <div id="left">
            </div>
            <div id="content">
                <div style="align-items: center">
                    <img style="padding-left: 10%" src="image/logo.png" alt="logo" />
                </div>
                <div id="login">
                    <h1 style="font-family: 'Microsoft YaHei UI'; color: #555555; font-size: x-large; margin-top: 10px; text-align: center; height: 32px;">健新关键用户考试系统</h1>

                    <div class="ct">
                        <div class="ct_right">
                            <asp:TextBox ID="TextBox5" runat="server" CssClass="btn" placeholder="用户名"></asp:TextBox>
                        </div>
                    </div>
                    <div class="ct">
                        <div class="ct_right">
                            <asp:TextBox ID="TextBox6" runat="server" CssClass="btn" TextMode="Password" placeholder="密码"></asp:TextBox>
                        </div>
                    </div>
                </div>
                <div style="margin-top: 0%; margin-left: 17%">

                    <%-- <input type="button"  runat="server" ImageUrl="~/image/btnLogin.jpg" OnClick="submitClick()" Height="82px" Width="323px" />--%>
                    <%--    <input type="button" value="提交" class="button" id="loginBtn" onclick="submitClick();" />--%>
                    <asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="~/image/btnLogin.jpg" OnClick="ImageButton1_Click" Visible="true" Height="69px" Width="252px" />
                </div>
            </div>
        </div>
        <div class="footer">
            <p style="font-size: 12px; color: #575757">
            </p>
        </div>
    </form>
</body>
</html>
